/*
	@file: log/include/LogPriority.h
	@author: Wolfhead
 */

#ifndef _LOG_LOG_PRIORITY_H_
#define _LOG_LOG_PRIORITY_H_

namespace logger
{

typedef unsigned int LogPriority;

enum 
{
	kPrioritySize = sizeof(LogPriority) * 8,

	kAll		= 0xFFFFFFFF,
	kNone		= 0x00000000,
	kBase 		= 0x00000001,
	// system priority
	kPerf		= kBase,
	kDebug3		= kPerf << 1,
	kDebug2     = kDebug3 << 1,
	kDebug1     = kDebug2 << 1,
	kDebug 		= kDebug1 << 1,
	kInfo		= kDebug << 1,
	kNotice		= kInfo << 1,
	kWarning	= kNotice << 1,
	kError		= kWarning << 1,
	kCritical	= kError << 1,
	// user priority
	kName		= kCritical << 1,
	// bound & mask
	kSystemBase = kDebug,
	kSystemTop  = kCritical,
	kSystemMask = kSystemTop | (kSystemTop - 1),

	kUserBase	= kSystemTop << 1,
	kUserMask 	= ~kSystemMask,
	kUserTop	= 0x80000000,
};

enum 
{
	Perf = kPerf,
	Debug3 = kDebug3,
	Debug2 = kDebug2,
	Debug1 = kDebug1,
	Debug = kDebug,
	Info = kInfo,
	Notice = kNotice,
	Warning = kWarning,
	Error = kError,
	Critical = kCritical,
};


} //namespace logger


#endif
